3.1453 \(\int \frac{1}{(-2+x) \sqrt{2+x}} \, dx\)

Optimal. Leaf size=14 \[ -\tanh ^{-1}\left (\frac{\sqrt{x+2}}{2}\right ) \]

[Out]

-ArcTanh[Sqrt[2 + x]/2]

_______________________________________________________________________________________

Rubi [A]  time = 0.0141759, antiderivative size = 14, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 13, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.154 \[ -\tanh ^{-1}\left (\frac{\sqrt{x+2}}{2}\right ) \]

Antiderivative was successfully verified.

[In]  Int[1/((-2 + x)*Sqrt[2 + x]),x]

[Out]

-ArcTanh[Sqrt[2 + x]/2]

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 2.40351, size = 10, normalized size = 0.71 \[ - \operatorname{atanh}{\left (\frac{\sqrt{x + 2}}{2} \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(1/(-2+x)/(2+x)**(1/2),x)

[Out]

-atanh(sqrt(x + 2)/2)

_______________________________________________________________________________________

Mathematica [B]  time = 0.00629183, size = 31, normalized size = 2.21 \[ \frac{1}{2} \log \left (2-\sqrt{x+2}\right )-\frac{1}{2} \log \left (\sqrt{x+2}+2\right ) \]

Antiderivative was successfully verified.

[In]  Integrate[1/((-2 + x)*Sqrt[2 + x]),x]

[Out]

Log[2 - Sqrt[2 + x]]/2 - Log[2 + Sqrt[2 + x]]/2

_______________________________________________________________________________________

Maple [B]  time = 0.011, size = 22, normalized size = 1.6 \[ -{\frac{1}{2}\ln \left ( 2+\sqrt{2+x} \right ) }+{\frac{1}{2}\ln \left ( -2+\sqrt{2+x} \right ) } \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(1/(-2+x)/(2+x)^(1/2),x)

[Out]

-1/2*ln(2+(2+x)^(1/2))+1/2*ln(-2+(2+x)^(1/2))

_______________________________________________________________________________________

Maxima [A]  time = 1.32925, size = 28, normalized size = 2. \[ -\frac{1}{2} \, \log \left (\sqrt{x + 2} + 2\right ) + \frac{1}{2} \, \log \left (\sqrt{x + 2} - 2\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(sqrt(x + 2)*(x - 2)),x, algorithm="maxima")

[Out]

-1/2*log(sqrt(x + 2) + 2) + 1/2*log(sqrt(x + 2) - 2)

_______________________________________________________________________________________

Fricas [A]  time = 0.207266, size = 28, normalized size = 2. \[ -\frac{1}{2} \, \log \left (\sqrt{x + 2} + 2\right ) + \frac{1}{2} \, \log \left (\sqrt{x + 2} - 2\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(sqrt(x + 2)*(x - 2)),x, algorithm="fricas")

[Out]

-1/2*log(sqrt(x + 2) + 2) + 1/2*log(sqrt(x + 2) - 2)

_______________________________________________________________________________________

Sympy [A]  time = 0.74843, size = 27, normalized size = 1.93 \[ \begin{cases} - \operatorname{acoth}{\left (\frac{\sqrt{x + 2}}{2} \right )} & \text{for}\: \frac{\left |{x + 2}\right |}{4} > 1 \\- \operatorname{atanh}{\left (\frac{\sqrt{x + 2}}{2} \right )} & \text{otherwise} \end{cases} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(-2+x)/(2+x)**(1/2),x)

[Out]

Piecewise((-acoth(sqrt(x + 2)/2), Abs(x + 2)/4 > 1), (-atanh(sqrt(x + 2)/2), Tru
e))

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.219974, size = 30, normalized size = 2.14 \[ -\frac{1}{2} \,{\rm ln}\left (\sqrt{x + 2} + 2\right ) + \frac{1}{2} \,{\rm ln}\left ({\left | \sqrt{x + 2} - 2 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(sqrt(x + 2)*(x - 2)),x, algorithm="giac")

[Out]

-1/2*ln(sqrt(x + 2) + 2) + 1/2*ln(abs(sqrt(x + 2) - 2))